[LINUX] PV-on-HVM: The elevator_init prototype changed in 2.6.10
authorIan Campbell <ian.campbell@xensource.com>
Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)
committerIan Campbell <ian.campbell@xensource.com>
Wed, 25 Oct 2006 12:58:30 +0000 (13:58 +0100)
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
linux-2.6-xen-sparse/drivers/xen/blkfront/vbd.c

index 4155ad6a2d91420201389cac15d686afbae9d1cd..7bf019c3f945e8ee8fd59a433d44ffe387da5307 100644 (file)
@@ -188,7 +188,11 @@ xlvbd_init_blk_queue(struct gendisk *gd, u16 sector_size)
        if (rq == NULL)
                return -1;
 
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,10)
        elevator_init(rq, "noop");
+#else
+       elevator_init(rq, &elevator_noop);
+#endif
 
        /* Hard sector size and max sectors impersonate the equiv. hardware. */
        blk_queue_hardsect_size(rq, sector_size);